package com.catchu.pattern.creational.观察者模式.test;

import com.catchu.pattern.creational.观察者模式.observer.ConcreteObserver;
import com.catchu.pattern.creational.观察者模式.subject.ConcreteSubject;

/**
 * 客户端测试
 */
public class Client {

    public static void main(String[] args) {
        ConcreteSubject subject = new ConcreteSubject();
        ConcreteObserver observer1 = new ConcreteObserver();
        ConcreteObserver observer2 = new ConcreteObserver();
        subject.addObserver(observer1);
        subject.addObserver(observer2);

        subject.doSomething();

    }


}
